#include "body.h"
#include "core.h"

#define ORIGIN_X_OFFSET 10
#define ORIGIN_Y_OFFSET 10
BODY_ITEM body_item;

void body_init(void)
{
    body_item.x = ORIGIN_X_OFFSET;
    body_item.y = ORIGIN_Y_OFFSET;
    body_item.energy = ORIGIN_ENERGY;
    body_item.last_direct = body_item.direction;
    body_item.direction = TOP;
    world_add_body(&body_item);
}

void body_step(void)
{
    body_item.last_direct = body_item.direction;
    body_item.direction = TOP;
    world_body_peep(&body_item); // 感知
}

void body_exit(void)
{

}
